<?php
    include_once 'modules/tuvi/views/HeaderView.php';
?>

<div class="grid">
    <div class="row">
        <?php
            include_once 'modules/tuvi/views/MenuView.php';
        ?>

        <div class="span9">
            <h2 id="_default"><i class="icon-accessibility on-left"></i><?php echo $act_title;?></h2>
            <div class="example">
                <form action="?mod=tuvi&act=<?php echo $act;?>" method="post" enctype="multipart/form-data">
                    <fieldset>
                        <legend>Quẻ bói - tử vi 2014</legend>
                        <lable>Tuổi</lable>
                        <div class="input-control text" data-role="input-control">
                            <input type="text" placeholder="Tý, sửu, mẹo,..." name="ages" value="<?php echo $ages;?>">
                            <button class="btn-clear" tabindex="-1"></button>
                        </div>
                        <lable>Nội dung quẻ</lable>
                        <div class="input-control textarea" data-role="input-control">
                            <textarea name="contents" rows="50" id="contents"><?php echo $contents;?></textarea>
                            <script>
                                CKEDITOR.replace( 'contents' );
                            </script>
                        </div>
                        <lable>Năm nhận diện gồm</lable>
                        <div class="input-control text" data-role="input-control">
                            <input type="text" placeholder="1990, 2002, 2014,..." name="years" value="<?php echo $years;?>">
                            <button class="btn-clear" tabindex="-1"></button>
                        </div>
                        <lable>Hình ảnh đại diện</lable>
                        <div class="input-control file">
                            <input type="file" name="file"/>
                            <button class="btn-file"></button>
                        </div>
                        <?php if ($act == 'edit' && $image != '') {?>
                        <div class="row">
                            <img alt="<?php echo $ages;?>" src="<?php echo $image;?>" class="shadow span3"/>
                            <input type="hidden" name="image" value="<?php echo $image;?>">
                        </div>
                        <?php }?>

                        <div class="row">
                            <input type="hidden" name="id" value="<?php echo $id;?>">
                            <input type="submit" name="submit" value="<?php echo $act_title;?>">
                        </div>
                    </fieldset>
                </form>
            </div>
        </div>
    </div>
</div>
<?php
    include_once 'layout/notice.php';
?>